home *** CD-ROM | disk | FTP | other *** search
- Path: acs5.bu.edu!lachesis
- From: lachesis@bu.edu (wai yip)
- Newsgroups: comp.lang.c
- Subject: modularity and data hiding
- Date: 30 Mar 1996 18:48:08 GMT
- Organization: Boston University
- Message-ID: <4jjvl9$phl@news.bu.edu>
- NNTP-Posting-Host: acs5.bu.edu
- X-Newsreader: TIN [version 1.2 PL2]
-
- hmmm, i seem to be posting here everytime i get a new homework
- assignment...don't know if it's a good thing. anyway, i seem to have a
- problem understanding data hiding. i have an assignment which requires me to
- store 3 letter airport codes in a binary search tree.
- i have to do it using modularity and data hiding with 5 files(a main file,
- interface.c file, implementation.c file, interface.h file and an
- implementation.h file).
-
- what i don't understand is why i need so many files. in the book i read, they
- only discussed the necessity for an interface.h file which stores declarations
- and definitions for prototypes and the implementation.c file which has all the
- functions for accessing the tree.
-
- so why do i need a .c and .h file for both the implementation and interface
- files? am i missing some important point in data hiding?
- hope i don't sound too stupid posting these types of questions ^_^
- any help would be appreciated.
-